package com.ljf.daily.costmanagement.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.ljf.common.model.BasisModel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;

import java.math.BigDecimal;
import java.util.Date;

/**
 * 费用管理明细对象  daily_dat_cost_management_detail
 *
 * @author LJF
 * @since 2025-04-03
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@ApiModel("费用管理明细")
@TableName("daily_dat_cost_management_detail")
@EqualsAndHashCode(callSuper = true)
public class DailyDatCostManagementDetail extends BasisModel {

	private static final long serialVersionUID = 1L;

	/**
	 * Java类型: Long
	 * 数据库类型: bigint
	 * 注释: ID
	 * {@link DailyDatCostManagementDetail#COL_ID}
	 */
	@TableId(value="id", type= IdType.AUTO)
	@JsonProperty("id")
	@ApiModelProperty(value = "ID")
	private Long id;

	/**
	 * Java类型: String
	 * 数据库类型: char(6)
	 * 注释: 编码
	 * {@link DailyDatCostManagementDetail#COL_CODE}
	 */
	@TableField("code")
	@JsonProperty("code")
	@ApiModelProperty(value = "编码")
	private String code;

	/**
	 * Java类型: Integer
	 * 数据库类型: smallint unsigned
	 * 注释: 排序
	 * {@link DailyDatCostManagementDetail#COL_SORT}
	 */
	@TableField("sort")
	@JsonProperty("sort")
	@ApiModelProperty(value = "排序")
	private Integer sort;

	/**
	 * Java类型: BigDecimal
	 * 数据库类型: decimal(8,2)
	 * 注释: 金额
	 * {@link DailyDatCostManagementDetail#COL_AMOUNT}
	 */
	@TableField("amount")
	@JsonProperty("amount")
	@ApiModelProperty(value = "金额")
	private BigDecimal amount;

	/**
	 * Java类型: BigDecimal
	 * 数据库类型: decimal(8,2)
	 * 注释: 数量
	 * {@link DailyDatCostManagementDetail#COL_QUANTITY}
	 */
	@TableField("quantity")
	@JsonProperty("quantity")
	@ApiModelProperty(value = "数量")
	private BigDecimal quantity;

	/**
	 * Java类型: BigDecimal
	 * 数据库类型: decimal(8,2)
	 * 注释: 剩余数量
	 * {@link DailyDatCostManagementDetail#COL_REMAIN_QUANTITY}
	 */
	@TableField("remain_quantity")
	@JsonProperty("remainQuantity")
	@ApiModelProperty(value = "剩余数量")
	private BigDecimal remainQuantity;

	/**
	 * Java类型: Date
	 * 数据库类型: datetime
	 * 注释: 购买时间
	 * {@link DailyDatCostManagementDetail#COL_PURCHASING_DATE}
	 */
	@TableField("purchasing_date")
	@JsonProperty("purchasingDate")
	@ApiModelProperty(value = "购买时间")
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
	private Date purchasingDate;


	/**
	 * ID
	 * {@link DailyDatCostManagementDetail#id}
	 */
	public static final String COL_ID = "id";
	/**
	 * 编码
	 * {@link DailyDatCostManagementDetail#code}
	 */
	public static final String COL_CODE = "code";
	/**
	 * 排序
	 * {@link DailyDatCostManagementDetail#sort}
	 */
	public static final String COL_SORT = "sort";
	/**
	 * 金额
	 * {@link DailyDatCostManagementDetail#amount}
	 */
	public static final String COL_AMOUNT = "amount";
	/**
	 * 数量
	 * {@link DailyDatCostManagementDetail#quantity}
	 */
	public static final String COL_QUANTITY = "quantity";
	/**
	 * 剩余数量
	 * {@link DailyDatCostManagementDetail#remainQuantity}
	 */
	public static final String COL_REMAIN_QUANTITY = "remain_quantity";
	/**
	 * 购买时间
	 * {@link DailyDatCostManagementDetail#purchasingDate}
	 */
	public static final String COL_PURCHASING_DATE = "purchasing_date";

}
